<?php
class User extends AppModel {

	var $name = 'User';

	var $validate = array(
		'username' => '/^.{5,40}$/',
		'password' => '/^.{5,40}$/',
		'email' => VALID_EMAIL		
		);
		
		//'website' => '/^(http|https):\/\/(([A-Z0-9][A-Z0-9_-]*)(\.[A-Z0-9][A-Z0-9_-]*)+)(:(\d+))?\//i'
	
	var $hasOne = array('Customer' => array(
							'className' => 'Customer',
							'conditions' => '',
							'order' => '',
							'dependent' => false,
							'foreignKey' => 'user_id'
							)
						);
						
	var $hasMany = array('Post' => array(
									'className' => 'Post',
									'conditions' => '',
									'order' => '',
									'foreignKey' => 'user_id'
									)
								);
	
}
?>